<template>
  <div class="demo">
    <div class="demo-title">位置</div>
    <div class="demo-content">
      <Radio.Group v-model:value="dotPosition" style="margin-bottom: 8px">
        <Radio.Button value="top">Top</Radio.Button>
        <Radio.Button value="bottom">Bottom</Radio.Button>
        <Radio.Button value="left">Left</Radio.Button>
        <Radio.Button value="right">Right</Radio.Button>
      </Radio.Group>
      <Carousel :dot-position="dotPosition">
        <div><h3>1</h3></div>
        <div><h3>2</h3></div>
        <div><h3>3</h3></div>
        <div><h3>4</h3></div>
      </Carousel>
    </div>
  </div>
</template>

<script lang="ts" setup>
  import { ref } from 'vue';
  import Radio from '@sscd/radio';
  import Carousel from '@sscd/carousel';
  import type { CarouselProps } from '@sscd/carousel';
  const dotPosition = ref<CarouselProps['dotPosition']>('top');
</script>

<style lang="less" scoped>
  .demo-content {
    :deep(.slick-slide) {
      text-align: center;
      height: 160px;
      line-height: 160px;
      background: #364d79;
      overflow: hidden;
      h3 {
        color: #fff;
      }
    }
  }
</style>
